home *** CD-ROM | disk | FTP | other *** search
/ Shareware Grab Bag / Shareware Grab Bag.iso / 007 / msd210.arc / MSD210.INT next >
Encoding:
Text File  |  1985-07-12  |  11.0 KB  |  193 lines

  1.         MSDOS 2.10 Interrupt Structure
  2.  
  3. Some of this information is based on data contained in the INTR?.TXT series
  4. of files maintained in DL 9 of the IBM PROFESSIONAL SIG (PCS-131, IBMSIG).
  5. Among the contributors to the INTR? series are:
  6.     Janet Jack    J. Weaver Jr.    John Cooper
  7.     Skip Gilbrech    Bob Jack    Jim Kyle
  8.  
  9. -----------------------------------------------------------------------------
  10. INT 0 - DIVIDE ERROR (8086/88 Chip Feature)
  11.     This interrupt is automatically called at the end of any DIV or IDIV
  12. operation that results in error. Normally set by DOS to display an error
  13. message and abort the program.
  14. -----------------------------------------------------------------------------
  15. INT 1 - SINGLE-STEP (8086/88 Chip Feature)
  16.     Generated at end of each machine instruction if TF bit in FLAGS is
  17. set. This is what makes the T command of DEBUG work for single-stepping. Is
  18. not generated after MOV to segment register or POP of segment register.
  19. -----------------------------------------------------------------------------
  20. INT 2 - NMI (Non Maskable Interrupt) (8086/88 Chip Feature)
  21.     Generated by NMI signal in hardware. This interrupt is not disabled by
  22. the CLI machine-code command. Used in IBM for memory parity error trapping.
  23. -----------------------------------------------------------------------------
  24. INT 3 - 1-BYTE INTERRUPT (8086/88 Chip Feature)
  25.     Generated by opcode 0CCh. Similar to 8080's RST instruction. Generally
  26. used to set breakpoints for DEBUG.
  27. -----------------------------------------------------------------------------
  28. INT 4 - OVERFLOW (8086/88 Chip Feature)
  29.     Generated by INTO instruction if OF flag is set. If flag is not set,
  30. INTO is effectively a NOP. Used to trap any arithmetic errors when program is
  31. ready to handle them rather than immediately when they occur.
  32. -----------------------------------------------------------------------------
  33. INTERRUPTS 5 thru 1F are all machine specific and may vary from one make of
  34. machine to another. The descriptions given here are for the IBM PC; known
  35. variations for other systems are indicated where applicable. Note that the
  36. Heath-Zenith Z100 produces a "WILD INTERRUPT" error message for ALL of these
  37. interrupt vectors.
  38. -----------------------------------------------------------------------------
  39. INT 5 - Print-Screen Key (IBM PC Specific)
  40.     Automatically called by keyboard scan when print-screen key is
  41. pressed. Normally executes routine to print the screen, but may call any
  42. routine that can safely be executed from inside the keyboard scanner.
  43. -----------------------------------------------------------------------------
  44. INT 6 - Not used, vectors to IRET. (IBM PC Specific)
  45. -----------------------------------------------------------------------------
  46. INT 7 - Not used, vectors to IRET. (IBM PC Specific)
  47. -----------------------------------------------------------------------------
  48. INT 8 - Vectored Hardware Line (IBM PC Specific)
  49.     Generated in response to IRQ 0 hardware interrupt line (system timer
  50. IRQ), if enabled via port 21.
  51. -----------------------------------------------------------------------------
  52. INT 9 - Vectored Hardware Line (IBM PC Specific)
  53.     Generated in response to IRQ 1 hardware interrupt line (keyboard IRQ),
  54. if enabled via port 21.
  55. -----------------------------------------------------------------------------
  56. INT 0AH - Vectored Hardware Line (IBM PC Specific)
  57.     Generated in response to IRQ 2 hardware interrupt line (unused IRQ),
  58. if enabled via port 21.
  59. -----------------------------------------------------------------------------
  60. INT 0BH - Vectored Hardware Line (IBM PC Specific)
  61.     Generated in response to IRQ 3 hardware interrupt line (unused IRQ),
  62. if enabled via port 21.
  63. -----------------------------------------------------------------------------
  64. INT 0CH - Vectored Hardware Line (IBM PC Specific)
  65.     Generated in response to IRQ 4 hardware interrupt line (serial port
  66. IRQ), if enabled via port 21. Normally not used and vector points to IRET.
  67. -----------------------------------------------------------------------------
  68. INT 0DH - Vectored Hardware Line (IBM PC Specific)
  69.     Generated in response to IRQ 5 hardware interrupt line (unused IRQ),
  70. if enabled via port 21.
  71. -----------------------------------------------------------------------------
  72. INT 0EH - Vectored Hardware Line (IBM PC Specific)
  73.     Generated in response to IRQ 6 hardware interrupt line (floppy disk
  74. IRQ), if enabled via port 21.
  75. -----------------------------------------------------------------------------
  76. INT 0FH - Vectored Hardware Line (IBM PC Specific)
  77.     Generated in response to IRQ 7 hardware interrupt line (printer IRQ),
  78. if enabled via port 21. Normally not used and vector points to IRET.
  79. -----------------------------------------------------------------------------
  80. INT 10 - VIDEO INTERFACE (IBM PC Specific)
  81. -----------------------------------------------------------------------------
  82. INT 11 - EQUIPMENT DETERMINATION (IBM PC Specific)
  83. -----------------------------------------------------------------------------
  84. INT 12 - MEMORY SIZE (IBM PC Specific)
  85. -----------------------------------------------------------------------------
  86. INT 13 - FLOPPY DISK INTERFACE (IBM PC Specific)
  87. -----------------------------------------------------------------------------
  88. INT 14 - SERIAL PORT INTERFACE (IBM PC Specific)
  89. -----------------------------------------------------------------------------
  90. INT 15 - CASSETTE SERVICE (IBM PC Specific)
  91. -----------------------------------------------------------------------------
  92. INT 16 - KEYBOARD INTERFACE (IBM PC Specific)
  93. -----------------------------------------------------------------------------
  94. INT 17 - PRINTER INTERFACE (IBM PC Specific)
  95. -----------------------------------------------------------------------------
  96. INT 18 - POINTER TO ROM BASIC ENTRY (IBM PC Specific)
  97. -----------------------------------------------------------------------------
  98. INT 19 - UNKNOWN (IBM PC Specific)
  99. -----------------------------------------------------------------------------
  100. INT 1A - TIME OF DAY (IBM PC Specific)
  101. -----------------------------------------------------------------------------
  102. INT 1B - CTRL-BREAK KEY (IBM PC Specific)
  103.     This interrupt is called when the keyboard scanner of the IBM machines
  104. detects CTRL and BREAK pressed at the same time. It normally points to a
  105. simple IRET so that it does nothing, but many programs change it to return a
  106. CTRL-C scan code and thus invoke INT 23.
  107. -----------------------------------------------------------------------------
  108. INT 1C - CLOCK TICK (IBM PC Specific)
  109.     This interrupt is called (in the IBM) at the end of each time-update
  110. operation by the real-time clock routines. It normally points to an IRET
  111. unless PRINT.COM has been installed.
  112. -----------------------------------------------------------------------------
  113. INT 1D - CRT PARAMETER TABLE (IBM PC Specific)
  114. -----------------------------------------------------------------------------
  115. INT 1E - FDC PARAMETER LIST (IBM PC Specific)
  116. -----------------------------------------------------------------------------
  117. INT 1F - CHAR SET (IBM PC Specific)
  118. -----------------------------------------------------------------------------
  119. INT 20 - PROGRAM TERMINATION (MSDOS generic)
  120.       NOTE:     NO PARAMETERS - RETURNS TO DOS
  121. -----------------------------------------------------------------------------
  122. INT 21 - DOS INTERFACE (MSDOS generic)
  123.       Reg AH = 0
  124.            
  125. -----------------------------------------------------------------------------
  126. INT 22 - TERMINATE ADDRESS (MSDOS generic)
  127.     FAR (DWORD) address of routine to be executed when program "returns to
  128. DOS". Should NOT ever be called.
  129. -----------------------------------------------------------------------------
  130. INT 23 - CONTROL "C" EXIT ADDRESS (MSDOS generic)
  131.     Automatically called from keyboard scanner when CTRL-C or CTRL-BREAK
  132. is detected. Normally aborts program and returns to DOS, but may be changed.
  133. -----------------------------------------------------------------------------
  134. INT 24 - FATAL ERROR ABORT ADDRESS (MSDOS generic)
  135.     Automatically called upon detection of unrecoverable disk error.
  136. Normally prints "Abort, Retry, or Ignore?" message and takes the reply, but
  137. may be changed if desired.
  138. -----------------------------------------------------------------------------
  139. INT 25 - ABSOLUTE DISK READ (MSDOS generic)
  140.     This routine reads data from the disk without regard to the file
  141. structure or directory. It begins at a "relative sector", which is simply the
  142. sector number, starting with 0, on the disk. That is, the first sector on the
  143. second side of track 0 would be sector 0AH, and the first sector on the first
  144. side of track 1 would be sector 12H.
  145.    ENTRY CONDITIONS:
  146.       AL = Drive number (0=A, 1=B, etc)
  147.       DS:BX = Disk Transfer Address (buffer)
  148.       CX = Number of sectors to read
  149.       DX = First relative sector to read. 0 reads boot
  150.            sector, 1 reads FAT, etc.
  151.    EXIT:
  152.       If carry set, AL=error code.
  153.       If carry not set, operation successful.
  154. NOTE:  This routine PUSHes the flags onto the stack when it is called, and
  155. does NOT remove them at exit. Be sure to POP the stack immediately after
  156. returning, to prevent overflow. All of the registers, not just those listed,
  157. are changed by the routine.
  158. -----------------------------------------------------------------------------
  159. INT 26 - ABSOLUTE DISK WRITE (MSDOS generic)
  160.     All parameters and conditions are the same as for INT 25, except that
  161. this routine WRITES to the disk rather than READing from it. Note that it
  162. does NOT update the FAT, directories, etc., and can easily destroy a disk
  163. unless carefully used.
  164. -----------------------------------------------------------------------------
  165. INT 27 - TERMINATE BUT STAY RESIDENT (MSDOS generic)
  166.       REG CS = CURRENT PROGRAM SEGMENT
  167.       REG DX = LAST PROGRAM BYTE + 1
  168.       NOTE:     RETURN IS TO DOS
  169. -----------------------------------------------------------------------------
  170. INT 28 - Internal routine for MSDOS
  171.       This interrupt is called from inside the "get input
  172. from keyboard" routine in DOS, if and only if it is safe to use
  173. INT 21 to access the disk at that time. It is used primarily by
  174. the PRINT.COM routines, but any number of other routines could
  175. be chained to it by saving the original vector, and calling it
  176. with a FAR call (or just JMPing to it) at the end of the new
  177. routine.
  178.       Until PRINT.COM installs its own routine, this
  179. interrupt vector simply points to an IRET opcode.
  180. -----------------------------------------------------------------------------
  181. INT 29 - Internal routine for MSDOS
  182.     This interrupt is called from the DOS output routines if output is
  183. going to a device rather than a file, and the device driver's attribute word
  184. has bit 3 (04H) set to "1". Nothing more is known about it at this time.
  185. -----------------------------------------------------------------------------
  186. INT 2E - UNKNOWN
  187. -----------------------------------------------------------------------------
  188. INT 30 - UNKNOWN
  189. -----------------------------------------------------------------------------
  190. INT 31 - UNKNOWN
  191. -----------------------------------------------------------------------------
  192. 
  193.